//package com.gome.gop.aspect;
//
//import com.gome.gop.service.SystemCheckService;
//import lombok.extern.slf4j.Slf4j;
//import org.aspectj.lang.JoinPoint;
//import org.aspectj.lang.annotation.Aspect;
//import org.aspectj.lang.annotation.Before;
//import org.aspectj.lang.annotation.Pointcut;
//import org.springframework.stereotype.Component;
//import org.springframework.web.context.request.RequestContextHolder;
//import org.springframework.web.context.request.ServletRequestAttributes;
//
//import javax.annotation.Resource;
//import javax.servlet.http.HttpServletRequest;
//
///**
// * 小程序校验切面校验
// *
// * @author liyt18
// */
//@Slf4j
//@Aspect
//@Component
//public class CardAspect {
//
//    @Resource
//    private  SystemCheckService systemCheckService;
//
//
//    /**
//     * 在注解的位置切入代码
//     */
//    @Pointcut("execution(* com.gome.gop.controller.*..*(..))")
//    public void check() {
//
//    }
//
//    /**
//     * 切面 配置通知
//     */
//    @Before("check()")
//    public void tokenCkeck(JoinPoint joinPoint) {
//
//        ServletRequestAttributes sra = (ServletRequestAttributes) RequestContextHolder.getRequestAttributes();
//        if (sra != null) {
//            HttpServletRequest request = sra.getRequest();
//            //记录操作日志
//            systemCheckService.saveOperationLog(request);
//
//        }
//
//    }
//}
